package com.he.service.impl;

import com.xxl.job.core.context.XxlJobHelper;
import com.xxl.job.core.handler.annotation.XxlJob;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.text.MessageFormat;

/**
 * @description: 测试XXL-JOB任务
 * @Author: HCL
 * @Date: 2024/11/12 10:40
 */
@Slf4j
@Component
public class XXlServiceImpl {

    @XxlJob("sendMSG")
    public String sendMSG() {
        String param= XxlJobHelper.getJobParam();
        log.info("测试发送消息成功：" + param);
        return MessageFormat.format("测试发送消息成功：{0}", param);


    }
}
